3.144 \(\int x^2 \tan ^2(a+i \log (x)) \, dx\)

Optimal. Leaf size=62 \[ -\frac {2 e^{2 i a} x^3}{x^2+e^{2 i a}}+6 e^{2 i a} x-6 e^{3 i a} \tan ^{-1}\left (e^{-i a} x\right )-\frac {x^3}{3} \]

[Out]

6*exp(2*I*a)*x-1/3*x^3-2*exp(2*I*a)*x^3/(exp(2*I*a)+x^2)-6*exp(3*I*a)*arctan(x/exp(I*a))

________________________________________________________________________________________

Rubi [F]  time = 0.05, antiderivative size = 0, normalized size of antiderivative = 0.00, number of steps used = 0, number of rules used = 0, integrand size = 0, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.000, Rules used = {} \[ \int x^2 \tan ^2(a+i \log (x)) \, dx \]

Verification is Not applicable to the result.

[In]

Int[x^2*Tan[a + I*Log[x]]^2,x]

[Out]

Defer[Int][x^2*Tan[a + I*Log[x]]^2, x]

Rubi steps

\begin {align*} \int x^2 \tan ^2(a+i \log (x)) \, dx &=\int x^2 \tan ^2(a+i \log (x)) \, dx\\ \end {align*}

________________________________________________________________________________________

Mathematica [A]  time = 0.13, size = 100, normalized size = 1.61 \[ \frac {2 x (\cos (3 a)+i \sin (3 a))}{\left (x^2+1\right ) \cos (a)-i \left (x^2-1\right ) \sin (a)}+4 i x \sin (2 a)+4 x \cos (2 a)-6 \cos (3 a) \tan ^{-1}(x (\cos (a)-i \sin (a)))-6 i \sin (3 a) \tan ^{-1}(x (\cos (a)-i \sin (a)))-\frac {x^3}{3} \]

Antiderivative was successfully verified.

[In]

Integrate[x^2*Tan[a + I*Log[x]]^2,x]

[Out]

-1/3*x^3 + 4*x*Cos[2*a] - 6*ArcTan[x*(Cos[a] - I*Sin[a])]*Cos[3*a] + (4*I)*x*Sin[2*a] + (2*x*(Cos[3*a] + I*Sin
[3*a]))/((1 + x^2)*Cos[a] - I*(-1 + x^2)*Sin[a]) - (6*I)*ArcTan[x*(Cos[a] - I*Sin[a])]*Sin[3*a]

________________________________________________________________________________________

fricas [A]  time = 0.50, size = 86, normalized size = 1.39 \[ -\frac {x^{5} - 11 \, x^{3} e^{\left (2 i \, a\right )} - 18 \, x e^{\left (4 i \, a\right )} - {\left (-9 i \, x^{2} e^{\left (3 i \, a\right )} - 9 i \, e^{\left (5 i \, a\right )}\right )} \log \left (x + i \, e^{\left (i \, a\right )}\right ) - {\left (9 i \, x^{2} e^{\left (3 i \, a\right )} + 9 i \, e^{\left (5 i \, a\right )}\right )} \log \left (x - i \, e^{\left (i \, a\right )}\right )}{3 \, {\left (x^{2} + e^{\left (2 i \, a\right )}\right )}} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(x^2*tan(a+I*log(x))^2,x, algorithm="fricas")

[Out]

-1/3*(x^5 - 11*x^3*e^(2*I*a) - 18*x*e^(4*I*a) - (-9*I*x^2*e^(3*I*a) - 9*I*e^(5*I*a))*log(x + I*e^(I*a)) - (9*I
*x^2*e^(3*I*a) + 9*I*e^(5*I*a))*log(x - I*e^(I*a)))/(x^2 + e^(2*I*a))

________________________________________________________________________________________

giac [B]  time = 0.56, size = 141, normalized size = 2.27 \[ -\frac {x^{5}}{3 \, {\left (x^{2} + \frac {e^{\left (4 i \, a\right )}}{x^{2}} + 2 \, e^{\left (2 i \, a\right )}\right )}} + \frac {10 \, x^{3} e^{\left (2 i \, a\right )}}{3 \, {\left (x^{2} + \frac {e^{\left (4 i \, a\right )}}{x^{2}} + 2 \, e^{\left (2 i \, a\right )}\right )}} - 6 \, \arctan \left (x e^{\left (-i \, a\right )}\right ) e^{\left (3 i \, a\right )} + \frac {35 \, x e^{\left (4 i \, a\right )}}{3 \, {\left (x^{2} + \frac {e^{\left (4 i \, a\right )}}{x^{2}} + 2 \, e^{\left (2 i \, a\right )}\right )}} + \frac {2 \, x e^{\left (4 i \, a\right )}}{x^{2} + e^{\left (2 i \, a\right )}} + \frac {8 \, e^{\left (6 i \, a\right )}}{{\left (x^{2} + \frac {e^{\left (4 i \, a\right )}}{x^{2}} + 2 \, e^{\left (2 i \, a\right )}\right )} x} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(x^2*tan(a+I*log(x))^2,x, algorithm="giac")

[Out]

-1/3*x^5/(x^2 + e^(4*I*a)/x^2 + 2*e^(2*I*a)) + 10/3*x^3*e^(2*I*a)/(x^2 + e^(4*I*a)/x^2 + 2*e^(2*I*a)) - 6*arct
an(x*e^(-I*a))*e^(3*I*a) + 35/3*x*e^(4*I*a)/(x^2 + e^(4*I*a)/x^2 + 2*e^(2*I*a)) + 2*x*e^(4*I*a)/(x^2 + e^(2*I*
a)) + 8*e^(6*I*a)/((x^2 + e^(4*I*a)/x^2 + 2*e^(2*I*a))*x)

________________________________________________________________________________________

maple [A]  time = 0.05, size = 48, normalized size = 0.77 \[ -\frac {7 x^{3}}{3}+\frac {2 x^{3}}{1+\frac {{\mathrm e}^{2 i a}}{x^{2}}}+6 \,{\mathrm e}^{2 i a} x -6 \arctan \left (x \,{\mathrm e}^{-i a}\right ) {\mathrm e}^{3 i a} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(x^2*tan(a+I*ln(x))^2,x)

[Out]

-7/3*x^3+2*x^3/(1+exp(2*I*a)/x^2)+6*exp(2*I*a)*x-6*arctan(x*exp(-I*a))*exp(3*I*a)

________________________________________________________________________________________

maxima [B]  time = 0.47, size = 269, normalized size = 4.34 \[ -\frac {2 \, x^{5} - x^{3} {\left (22 \, \cos \left (2 \, a\right ) + 22 i \, \sin \left (2 \, a\right )\right )} - x {\left (36 \, \cos \left (4 \, a\right ) + 36 i \, \sin \left (4 \, a\right )\right )} - {\left (x^{2} {\left (18 \, \cos \left (3 \, a\right ) + 18 i \, \sin \left (3 \, a\right )\right )} + {\left (18 \, \cos \left (2 \, a\right ) + 18 i \, \sin \left (2 \, a\right )\right )} \cos \left (3 \, a\right ) - 18 \, {\left (-i \, \cos \left (2 \, a\right ) + \sin \left (2 \, a\right )\right )} \sin \left (3 \, a\right )\right )} \arctan \left (\frac {2 \, x \cos \relax (a)}{x^{2} + \cos \relax (a)^{2} - 2 \, x \sin \relax (a) + \sin \relax (a)^{2}}, \frac {x^{2} - \cos \relax (a)^{2} - \sin \relax (a)^{2}}{x^{2} + \cos \relax (a)^{2} - 2 \, x \sin \relax (a) + \sin \relax (a)^{2}}\right ) + {\left (9 \, x^{2} {\left (-i \, \cos \left (3 \, a\right ) + \sin \left (3 \, a\right )\right )} + 9 \, {\left (-i \, \cos \left (2 \, a\right ) + \sin \left (2 \, a\right )\right )} \cos \left (3 \, a\right ) + {\left (9 \, \cos \left (2 \, a\right ) + 9 i \, \sin \left (2 \, a\right )\right )} \sin \left (3 \, a\right )\right )} \log \left (\frac {x^{2} + \cos \relax (a)^{2} + 2 \, x \sin \relax (a) + \sin \relax (a)^{2}}{x^{2} + \cos \relax (a)^{2} - 2 \, x \sin \relax (a) + \sin \relax (a)^{2}}\right )}{6 \, x^{2} + 6 \, \cos \left (2 \, a\right ) + 6 i \, \sin \left (2 \, a\right )} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(x^2*tan(a+I*log(x))^2,x, algorithm="maxima")

[Out]

-(2*x^5 - x^3*(22*cos(2*a) + 22*I*sin(2*a)) - x*(36*cos(4*a) + 36*I*sin(4*a)) - (x^2*(18*cos(3*a) + 18*I*sin(3
*a)) + (18*cos(2*a) + 18*I*sin(2*a))*cos(3*a) - 18*(-I*cos(2*a) + sin(2*a))*sin(3*a))*arctan2(2*x*cos(a)/(x^2
+ cos(a)^2 - 2*x*sin(a) + sin(a)^2), (x^2 - cos(a)^2 - sin(a)^2)/(x^2 + cos(a)^2 - 2*x*sin(a) + sin(a)^2)) + (
9*x^2*(-I*cos(3*a) + sin(3*a)) + 9*(-I*cos(2*a) + sin(2*a))*cos(3*a) + (9*cos(2*a) + 9*I*sin(2*a))*sin(3*a))*l
og((x^2 + cos(a)^2 + 2*x*sin(a) + sin(a)^2)/(x^2 + cos(a)^2 - 2*x*sin(a) + sin(a)^2)))/(6*x^2 + 6*cos(2*a) + 6
*I*sin(2*a))

________________________________________________________________________________________

mupad [B]  time = 2.23, size = 52, normalized size = 0.84 \[ -6\,{\left ({\mathrm {e}}^{a\,2{}\mathrm {i}}\right )}^{3/2}\,\mathrm {atan}\left (\frac {x}{\sqrt {{\mathrm {e}}^{a\,2{}\mathrm {i}}}}\right )-\frac {x^3}{3}+4\,x\,{\mathrm {e}}^{a\,2{}\mathrm {i}}+\frac {2\,x\,{\mathrm {e}}^{a\,4{}\mathrm {i}}}{x^2+{\mathrm {e}}^{a\,2{}\mathrm {i}}} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(x^2*tan(a + log(x)*1i)^2,x)

[Out]

4*x*exp(a*2i) - x^3/3 - 6*exp(a*2i)^(3/2)*atan(x/exp(a*2i)^(1/2)) + (2*x*exp(a*4i))/(exp(a*2i) + x^2)

________________________________________________________________________________________

sympy [A]  time = 0.32, size = 66, normalized size = 1.06 \[ - \frac {x^{3}}{3} + 4 x e^{2 i a} + \frac {2 x e^{4 i a}}{x^{2} + e^{2 i a}} - 3 \left (- i \log {\left (x - i e^{i a} \right )} + i \log {\left (x + i e^{i a} \right )}\right ) e^{3 i a} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(x**2*tan(a+I*ln(x))**2,x)

[Out]

-x**3/3 + 4*x*exp(2*I*a) + 2*x*exp(4*I*a)/(x**2 + exp(2*I*a)) - 3*(-I*log(x - I*exp(I*a)) + I*log(x + I*exp(I*
a)))*exp(3*I*a)

________________________________________________________________________________________